#include "NMath.h"

NVector2::NVector2()
{
}

NVector2::NVector2(float x, float y)
	:X(x), Y(y)
{
}

NVector2::~NVector2()
{
}

bool NVector2::operator== (const NVector2& rhs) const
{
	if(rhs.X == this->X && rhs.Y == this->Y)
	{
		return true;
	}
	return false;
}

bool NVector2::operator!= (const NVector2& rhs) const
{
	return !this->operator==(rhs);
}

NVector2 NVector2::operator+ (const NVector2 rhs) const
{
	NVector2 result;

	result.X = this->X + rhs.X;
	result.Y = this->Y + rhs.Y;

	return result;
}

NVector2 NVector2::operator- (const NVector2 rhs) const
{
	NVector2 result;

	result.X = this->X - rhs.X;
	result.Y = this->Y - rhs.Y;

	return result;
}




NVector3::NVector3()
{
}

NVector3::NVector3(NVector2 vector)
	:NVector2(vector), Z(0)
{
}

NVector3::NVector3(float x, float y, float z)
	:NVector2(x, y), Z(z)
{
}

NVector3::~NVector3()
{
}

bool NVector3::operator== (const NVector3& rhs) const
{
	if(NVector2::operator==(rhs) && this->Z == rhs.Z)
	{
		return true;
	}
	return false;
}

bool NVector3::operator!= (const NVector3& rhs) const
{
	return !this->operator==(rhs);
}

NVector3 NVector3::operator+ (const NVector3 rhs) const
{
	NVector3 result = NVector2::operator+(rhs);

	result.Z = this->Z + rhs.Z;

	return result;
}

NVector3 NVector3::operator- (const NVector3 rhs) const
{
	NVector3 result = NVector2::operator-(rhs);

	result.Z = this->Z * rhs.Z;
	
	return result;
}





NMatrix2::NMatrix2()
{
}

NMatrix2::~NMatrix2()
{
}


NMatrix3::NMatrix3()
{
}

NMatrix3::~NMatrix3()
{
}

NMatrix4::NMatrix4()
{
}

NMatrix4::~NMatrix4()
{
}